The present invention relates to a defect inspection method, and an apparatus, for detecting the difference between corresponding signals, comparing the detected difference with a threshold value, and judging the part to be a defect when the difference is larger than the threshold value. More particularly, the present invention relates to an image defect inspection method, and an apparatus, for detecting the difference in gray level between corresponding parts of two images, comparing the detected gray level difference with a threshold value, and judging the part to be a defect when the gray level difference is larger than the threshold value, and also relates to an appearance inspection apparatus for detecting a defect in a semiconductor circuit pattern formed on a semiconductor wafer by using the method. Still more particularly, the present invention relates to a technique to determine a threshold value in accordance with a signal (image).
The object of the present invention relates to an image processing method, and to an apparatus for judging a part where the difference is large enough to be a defect by making a comparison between the corresponding parts of two images that should be essentially the same. Here, an appearance inspection apparatus (inspection machine), which detects a defect in a semiconductor circuit pattern formed on a semiconductor wafer in the semiconductor manufacturing process, is taken as an example but the present invention is not limited to this case. A general appearance inspection apparatus is a bright field inspection apparatus, in which the surface of an object is illuminated in the vertical direction and the image of the reflected light is captured, but a dark field inspection apparatus, which does not capture the illumination light directly, can also be used. In the case of a dark field inspection apparatus, the surface of an object is illuminated in an oblique direction or in the vertical direction and a sensor is arranged so as not to detect regularly reflected light and the dark field image of the surface of the object is obtained by sequentially scanning the part that is irradiated with illuminating light. Therefore, some dark field apparatuses may not use an image sensor, but the present invention is also applicable to them. As described above, the present invention is applicable to any image processing method and any apparatus as long as the method and the apparatus make a comparison between the corresponding parts of two images (signals) that should be essentially the same and judge a part where the difference is large to be a defect.
In the semiconductor manufacturing process, many chips (dies) are formed on a semiconductor wafer. Patterns are formed across several layers on each die. The completed die is electrically tested by a probe and a tester and if found defective, it is excluded from the assembling process. In the semiconductor manufacturing process, the yield is a very important factor and the result of the above-mentioned electrical test is fed back to the manufacturing process and used for the management of each process. However, the semiconductor manufacturing process consists of many processes and it takes a very long time before an electrical test is conducted after the manufacturing starts, therefore, when a process is found defective based on the electrical test result, many wafers are already in the middle of the process, and it is impossible to efficiently utilize the test result in order to improve the yield. Because of this, a pattern defect inspection is conducted in order to detect a defect by inspecting patterns formed in an intermediate process. If a pattern inspection test is conducted in some processes, among all of the processes, it is possible to detect a defect that appears after the previous inspection is conducted and the inspection result can be immediately reflected in the process management.
In an appearance inspection apparatus currently used, a semiconductor wafer is illuminated, the image of a semiconductor circuit pattern is optically captured and an image electric signal is generated, and the image electric signal is further converted into a multi-valued digital signal (digital gray level signal). Then, the difference signal (gray level difference signal) between the digital signal and the gray level signal of a reference pattern is generated and a part where the difference is larger than a fixed threshold value is judged to be a defect. The reference pattern is in general a neighboring die or a neighboring similar pattern. Then, a defect grouping process is carried out, in which the part that has been judged to be a defect is further inspected in detail, and whether it is a true defect that adversely affects the yield is judged. The defect grouping process requires a long time for processing because it is necessary to inspect the part that has been judged to be a defect in detail. Therefore, when a part is judged to be a defect or not, it is required to judge a true defect to be a defect without fail, and not to judge a part that is not a true defect to be a defect, if possible.
Therefore, setting of a threshold value is essential. If a threshold value is set to too small a value, the number of pixels to be judged to be a defect increases and it may happen that even a part that is not a true defect is judged to be a defect, and a problem occurs that the time required for the defect grouping process is lengthened. On the contrary, if a threshold value is set to too large a value, it may happen that even a part that is a true defect is judged to be nondefective, and a problem occurs that the inspection is insufficient.
In the conventional method for automatically determining a threshold value based on samples, a digital gray level signal of the pattern of a similar sample is generated in advance, a gray level difference signal is further generated, and a histogram of differences is created. Then, a variation reference difference, which is set by a fixed proportion of a part where the difference is large in the histogram, is obtained and a detection threshold value is calculated by adding a fixed difference thereto. This is because it is thought that a case where the variation in the distribution of differences is large actually brings about a problem, and an attempt is made to suppress the number of pixels to be judged to be a defect from increasing so much even in such a case. According to this method, the variation reference difference varies depending on samples, but the fixed difference to be added is constant, and does not vary depending on the samples, therefore, there is a problem that it is not possible to obtain a proper threshold value when the noise level changes.
In order to solve the above-mentioned problem, various methods for determining a threshold value have been proposed. For example, Japanese Unexamined Patent Publication (Kokai) No. 4-107946 has disclosed a method for determining a threshold value based on the statistic of gray level differences calculated at plural parts of a pattern. In concrete terms, the maximum value of the gray level difference is obtained for each part and a histogram of maximums is created. Then an initial value of an optimum threshold value is set based on the average and the standard deviation, and the optimum threshold value is determined by correcting the initial value based on the number of pixels to be detected as a defect. However, there are problems in this method that (1) it is necessary to measure samples in advance and that (2) it is necessary to make plural inspections. Moreover, although it is stated that a threshold value is most proper when the number of detected defects changes suddenly, no concrete method has been described for obtaining such a threshold value at which the number changes suddenly.
Japanese Unexamined Patent Publication (Kokai) No. 5-47886 has disclosed a method in which a curve approximation is obtained by the relationship between the gray level difference and the frequency and a gray level difference at which the curve approximation becomes zero is taken as an optimum threshold value. However, although the relationship between the gray level difference and the frequency is represented by a curve, the curve does not necessarily become zero, therefore, there may be a case where a curve approximation does not become zero. Moreover, there may be a case where even a straight line does not become zero depending on the value of its slope. Therefore, there may be a case where setting is impossible. Although it is stated that such a curve is easy to obtain, actually it is not possible to easily obtain the curve because of its dependency on the distribution of gray level differences, and a problem occurs that the processing time is lengthened.
Japanese Unexamined Patent Publication (Kokai) No. 2002-22421 has disclosed a method for carrying out an error probability conversion using the standard deviation. However, there are problems in this method that (1) because the standard deviation is directly calculated from gray level differences, a tremendous amount of calculation is required and the processing time is lengthened, and that (2) because an error probability value is used, instead of a gray level difference, for defect judgment, it is necessary to calculate an error probability value for each gray level difference and the processing time is lengthened. Moreover, because the standard deviation is used, this method is applicable only to a normal distribution, not to other distributions.
There are demands for automatic inspection of a semiconductor pattern and for automatic setting of a threshold value. In order to realize this, it is necessary to set an optimum threshold value by immediately processing detected gray level differences and make a judgment in identifying a defect based on the threshold value, and it is possible to automatically set a threshold value by automatically following the above-mentioned method. On the other hand, however, it is required to shorten the inspection time in order to improve throughput, and there are problems in the above-mentioned method that it is necessary to measure the samples plural times in advance, that the processing time is long, and therefore that this method is not suitable for automatic setting of a threshold value of an inspection apparatus with a high throughput.
Particularly in an actual inspection of a semiconductor pattern, the noise level differs depending on: the position in a die; the position of the die on a wafer; and the wafer, even when the same semiconductor pattern is formed thereon. Therefore, it is necessary to set an optimum threshold value by timely processing the detected gray level differences, but the above-mentioned method cannot meet the demand.
As described above, the conventional method for determining a threshold value cannot be actually applied to an appearance inspection apparatus capable of automatically setting a threshold value and having a high throughput.
Moreover, it has been assumed so far that gray levels of two images to be compared are distributed with the center being the same value and that the number of pixels, gray level difference between which is zero, is largest, but in an actual case, this is not assured and an inspection error results.